<template>
  <div class="mui-pages" style="background-color: #fff;">
    <header class="mui-bar mui-bar-nav">
      <div class="header-common-title flex-justify-start">
        <a @click="fn.back()" href="javascript:void(0)"><img class="back-btn" src="../../../../static/images/back.png"></a>
        <div class="header-search flex-center">考核规则</div>
      </div>
    </header>
    <div class="mui-scroll-wrapper mui-page-content record-member-lists">
      <div class="mui-scroll meeting-popover">
        <h4 class="meeting-popover flex-center">一、支部党建考核规则</h4>
        <div class="list-textarea meeting-popover group-study">
          <p class="answer-notice">
            <template v-for="(item,index) in data.groupList" >{{index+1}}. {{item.name}} ({{computerScore(item)}}分)<br/></template>
          </p>
        </div>
        <h4 class="work-message-lists flex-center">二、个人党员考核规则</h4>
        <div class="list-textarea meeting-popover group-study">
          <p class="answer-notice">
            <template v-for="(item,index) in data.personalList" >{{index+1}}. {{item.name}} ({{computerScore(item)}}分)<br/></template>
          </p>
        </div>
      </div>
    </div>
  </div>
</template>
<script>
  import footerbar from '../common/footerbar.vue'
  import tools from '@/utils/tools'
  import api from '@/common/config/api'
  import loginService from '@/service/loginService'
  import moment from 'moment'

  export default {
    components: {
      footerbar
    },
    name: '',
    data() {
      return {
        fn: tools,
        data:{}
      }
    },
    created() {
      this.loadData()
    },
    methods: {
      computerScore(item){
        return (item.plusReduceStatus == 1? '+' : '-') + item.points
      },
      loadData() {
        let data = {
          token: tools.getToken()
        }
        loginService.getCheckRuleData(data).then(res => {
          console.log(res)
          if(res.code===200) {
            this.data = res.data
          }
        })
      }
    }
  }
</script>
<style>
  .meeting-popover {width:100%;}
</style>
